package com.plentitude.easytrader.ui;

import com.plentitude.easytrader.R;
import android.app.Activity;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.view.View;
import android.view.Window;
import android.widget.TextView;


/**
 * Application account page.
 * 
 * @author team@getstarted.com.ua
 */
public class AccountActivity extends Activity {

	
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        requestWindowFeature(Window.FEATURE_CUSTOM_TITLE);
        
        setContentView(R.layout.activity_account);
    	TextView webLink = (TextView) findViewById(R.id.webLink);
    	webLink.setOnClickListener(new android.view.View.OnClickListener() {
			@Override
			public void onClick(View v) {
				onWebLinkClick(); 
			}
    	});
        getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.title);
    }

    /** Handle "settings restore" action. */
    public void onInfoClose(View v) {
    	finish();
    }
    
	@Override
    protected void onDestroy() {
    	super.onDestroy();
    }
    
	
    // PRIVATE METHODS
    
	/** Handle "web link" action. */
	private void onWebLinkClick() {
		startActivity(new Intent(Intent.ACTION_VIEW , Uri.parse(Keys.INFO_URL)));
	}

}
